﻿//////////////////////////////////////////////////////////////////////////////
//
//  Copyright © 1998-2024 Glodon Company Limited.  All rights reserved.
//
//  Use of this software is subject to the terms of the Glodon license
//  agreement provided at the time of installation or download, or which
//  otherwise accompanies this software in either electronic or hard copy form.  
//
//////////////////////////////////////////////////////////////////////////////

#pragma once
#include "GcmpModelInterface.h"
#include "IDatasetFilter.h"
#include "OwnerPtr.h"
#include <vector>

namespace gcmp
{
    /// \brief 逻辑或类型的数据集过滤器
    ///
    /// 提供逻辑或类型的数据集过滤器相关接口
    class GCMP_MODEL_INTERFACE_EXPORT IDatasetLogicalAndFilter : virtual public IDatasetFilter
    {
        DEFINE_CAST_DERIVED(gcmp::IDatasetLogicalAndFilter, gcmp::IDatasetFilter)
    public:
        /// \brief 静态构造方法
        ///
        /// \return OwnerPtr<IDatasetLogicalAndFilter> 新建的逻辑与过滤器
        static OwnerPtr<IDatasetLogicalAndFilter> Create();
    public:
        /// \ brief 获取子数据集过滤器列表
        ///
        /// \return std::vector<const IDatasetFilter*> 子数据集过滤器列表
        virtual std::vector<const IDatasetFilter*> GetFilters() const = 0;

        /// \ brief 设置子数据集过滤器列表
        ///
        /// \param filters 子数据集过滤器列表
        virtual void SetFilters(std::vector<OwnerPtr<IDatasetFilter>>& filters) = 0;
    };
}